#define _CRT_SECURE_NO_WARNINGS 1
ElementType Average(ElementType S[], int N)
{
    int i = 0;
    double sum = 0.0;
    double ave = 0.0;
    for (i = 0; i < N; i++)
    {
        sum += S[i];
    }
    return sum / N;
}